package com.ktgj.customer.service.impl;

import java.util.List;
import com.ktgj.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ktgj.customer.mapper.DepositRefundcashMapper;
import com.ktgj.customer.domain.DepositRefundcash;
import com.ktgj.customer.service.IDepositRefundcashService;

/**
 * 预留款返现申请
Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-07-27
 */
@Service
public class DepositRefundcashServiceImpl implements IDepositRefundcashService 
{
    @Autowired
    private DepositRefundcashMapper depositRefundcashMapper;

    /**
     * 查询预留款返现申请

     * 
     * @param refundcashId 预留款返现申请
ID
     * @return 预留款返现申请

     */
    @Override
    public DepositRefundcash selectDepositRefundcashById(Long refundcashId)
    {
        return depositRefundcashMapper.selectDepositRefundcashById(refundcashId);
    }

    /**
     * 查询预留款返现申请
列表
     * 
     * @param depositRefundcash 预留款返现申请

     * @return 预留款返现申请

     */
    @Override
    public List<DepositRefundcash> selectDepositRefundcashList(DepositRefundcash depositRefundcash)
    {
        return depositRefundcashMapper.selectDepositRefundcashList(depositRefundcash);
    }

    /**
     * 新增预留款返现申请

     * 
     * @param depositRefundcash 预留款返现申请

     * @return 结果
     */
    @Override
    public int insertDepositRefundcash(DepositRefundcash depositRefundcash)
    {
        depositRefundcash.setCreateTime(DateUtils.getNowDate());
        return depositRefundcashMapper.insertDepositRefundcash(depositRefundcash);
    }

    /**
     * 修改预留款返现申请

     * 
     * @param depositRefundcash 预留款返现申请

     * @return 结果
     */
    @Override
    public int updateDepositRefundcash(DepositRefundcash depositRefundcash)
    {
        return depositRefundcashMapper.updateDepositRefundcash(depositRefundcash);
    }

    /**
     * 批量删除预留款返现申请

     * 
     * @param refundcashIds 需要删除的预留款返现申请
ID
     * @return 结果
     */
    @Override
    public int deleteDepositRefundcashByIds(Long[] refundcashIds)
    {
        return depositRefundcashMapper.deleteDepositRefundcashByIds(refundcashIds);
    }

    /**
     * 删除预留款返现申请
信息
     * 
     * @param refundcashId 预留款返现申请
ID
     * @return 结果
     */
    @Override
    public int deleteDepositRefundcashById(Long refundcashId)
    {
        return depositRefundcashMapper.deleteDepositRefundcashById(refundcashId);
    }
}
